package com.sw.small_world.fragment.message;

import android.content.Context;
import android.graphics.Color;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentActivity;
import android.view.View;
import android.widget.TextView;

import com.sw.small_world.R;
import com.sw.small_world.activity.MainActivity;
import com.sw.small_world.fragment.base.BaseFragment;
import com.sw.small_world.fragment.base.BasePagerFragment;
import com.sw.small_world.fragment.base.FragmentFactory;
import com.sw.small_world.utils.CommonUtils;
import com.sw.small_world.utils.ConstantUtils;
import com.sw.small_world.utils.StartUtils;

/**
 * Created by Administrator on 2017/3/16.
 */

public class MessageFragment extends BasePagerFragment {

    private MainActivity activity;

    @Override
    protected Fragment setFragment(int position) {
        return FragmentFactory.createForMessage(position);
    }

    @Override
    protected String[] setTitles() {
        return CommonUtils.getStringArray(R.array.message);
    }

    @Override
    protected void setActionBar() {
        activity = (MainActivity) getActivity();
        activity.renMai.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                StartUtils.startActivityById(activity,R.id.item_my_friends);
            }
        });
    }
}
